from django.urls import path
from goods.views import *
urlpatterns = [
    # 轮番图路由
    path('getCarousel/', CarouselView.as_view()),
    # 获取各类商品数据
    path('oneCategory/all/', GoodsCateName.as_view()),
    # 热门商品
    path('getHotProduct/', HotGoods.as_view()),
    # 获取类别
    path('category/getCategory/', CategoryView.as_view()),
    # 根据id获取类别下的所有商品
    path('good/getProductByCategory/', GoodsCateId.as_view()),
    # 获取所有商品
    path('good/getAllProduct/', GoodsView.as_view()),
    # 商品id
    path('onegood/imgs/', GoodPicture.as_view()),
    # 商品详情
    path('onegood/', GoodDetail.as_view()),
    # 历史浏览记录
    path("oneGood/history/", AddHistory.as_view()),
    # 添加收藏
    path("collects/", CollectView.as_view()),
    # 查看收藏
    path("collects/user/getCollect/", GoodsFav.as_view()),
    # 删除收藏
    path("collects/user/deleteCollect/", CollectDel.as_view())
]
